<script setup lang="ts">
import type { NuxtError } from '#app';

const router = useRouter();

const props = defineProps({
    error: Object as () => NuxtError
})
console.log(props.error);

</script>
<template>
    <div>
        <span v-if="error?.statusCode === 404">
            <h1>页面未找到</h1>
        </span>
        <span v-else-if="error?.statusCode === 429">
            <h1>请求繁忙</h1>
        </span>
    </div>
</template>
<style></style>